Skip to content

)} ,System.Func{-0,--1})}

OrderedLiveQuery.GroupBy(Func) method

Defined in

Type: OrderedLiveQuery Namespace: ReactiveList.Reactive.Queries Assembly: ReactiveList.Reactive.dll

Applies to

net11.0, net10.0, net47, net471, net472, net48, net481

Overloads

  1. public GroupedLiveQuery<TKey, T> GroupBy<TKey>(Func<T, TKey> keySelector) where TKey : notnull

  2. public GroupedLiveQuery<TKey, TElement> GroupBy<TKey, TElement>(Func<T, TKey> keySelector, Func<T, TElement> elementSelector) where TKey : notnull where TElement : notnull

1. Overload

public GroupedLiveQuery<TKey, T> GroupBy<TKey>(Func<T, TKey> keySelector) where TKey : notnull

View source (opens in a new tab)

Summary: Groups the ordered items by a key. Members of each group keep the query's order.

Type parameters

NameDescription
TKeyThe grouping key type.

Parameters

NameTypeDescription
keySelectorFunc (opens in a new tab)Takes the grouping key from an item.

Returns: GroupedLiveQuery -- The grouped query.

2. Overload

public GroupedLiveQuery<TKey, TElement> GroupBy<TKey, TElement>(Func<T, TKey> keySelector, Func<T, TElement> elementSelector) where TKey : notnull where TElement : notnull

View source (opens in a new tab)

Summary: Groups the ordered items by a key and holds a value taken from each item in the groups. Members of each group keep the query's order.

Type parameters

NameDescription
TKeyThe grouping key type.
TElementThe type of the values the groups hold.

Parameters

NameTypeDescription
keySelectorFunc (opens in a new tab)Takes the grouping key from an item.
elementSelectorFunc (opens in a new tab)Takes the value a group holds from an item.

Returns: GroupedLiveQuery -- The grouped query.